﻿<extend name="../Public/base" />
<block name="title">{$TITLE}列表</block>
<block name="body">
    <div class="cl pd-5 bg-1 bk-gray mt-20">
        <span class="r">共有数据：<strong>{$count}</strong> 条</span>
    </div>
    <div class="mt-20">
        <p class="c-white"><span style="background-color:#f37b1d">注意：这里只是使用了第三方用户，留有uid字段接口，可根据自我需求创建本站会员绑定！</span></p>
    </div>
    <div class="mt-20">
        <table class="table table-border table-bordered table-bg">
            <thead>
                <tr class="text-c">
                    <th width="5%">id</th>
                    <th width="10%">来源</th>
                    <th width="10%">昵称</th>
                    <th width="10%">头像</th>
                    <th width="10%">绑定用户</th>
                    <th width="15%">创建时间</th>
                    <th width="15%">最后登录时间</th>
                    <th width="5%">登录次数</th>
                    <th width="5%">状态</th>
                    <th width="15%">操作</th>
                </tr>
            </thead>
            <tbody>
            <volist name="list" id="info">
                <tr class="text-c">
                    <td>{$info['oauth_id']}</td>
                    <td>{$info['type']}</td>
                    <td>{$info['nickname']}</td>
                    <td><img width="25" height="25" src="{:U('user/public/avatar',array('id'=>$info['oauth_id']))}" /></td>
                    <td>{$info['user_id']}</td>
                    <td>{$info['create_time']|date="Y-m-d H:i:s",###}</td>
                    <td>{$info['last_login_time']|date="Y-m-d H:i:s",###}</td>
                    <td>{$info['login_times']}</td>
                    <td>
                        <eq name='info.status' value='1'>
                            <span class="label label-success radius">已启用</span>
                            <else/>
                            <span class="label radius">已停用</span>
                        </eq>
                    </td>
                    <td class="f-14">
                        <eq name='info.status' value='1'>
                            <a  onclick="change_status('{$info.oauth_id}')" href="javascript:;" title="停用"><i class="Hui-iconfont">&#xe631;</i></a>
                            <else/>
                            <a  onclick="change_status('{$info.oauth_id}')" href="javascript:;" title="启用"><i class="Hui-iconfont">&#xe615;</i></a>
                        </eq>
                        <a title="删除" href="javascript:;" onclick="del('{$info.oauth_id}','oauth_id')" class="ml-5">
                            <i class="Hui-iconfont">&#xe6e2;</i>
                        </a>
                    </td>
                </tr>
            </volist>
            </tbody>
        </table>
        </div>
        <div class='paging_simple_numbers'>
           {$page}
        </div>
    </div>
</block>
<block name="js">
    <script type="text/javascript">
        function change_status(id) {
            action('确认要改变第三方用户状态吗？',id,"{:U('changeStatus')}",'oauth_id');
        }
    </script>
</block>